/**
 * Created by Administrator on 2018/4/26/026.
 */
var MainMenuScene = cc.Scene.extend({
    backgroundLayer     : null,
    mainLayer           : null,
    unlocLayer          : null,
    ctor:function(){
        cc.log("======MainMenuScene ctor======");
        this._super();
        cc.audioEngine.playMusic(res.sd_mm_BGMusic_mp3, true);
    },

    onEnter:function () {
        this._super();
        //加载【背景层】
        this.loadBackgroudLayer();
        //加载【主层】
        this.loadMainlayer();
    },

    loadBackgroudLayer:function(){
        cc.log("======MainMenuScene loadBackgroudLayer======");
        this.backgroundLayer = new BackgroundLayer();
        this.addChild(this.backgroundLayer);
    },

    loadMainlayer:function(){
        this.mainLayer = new MMainlayer();
        this.addChild(this.mainLayer);
    },
});